//
//  SmallLiveCollectiontViewCell.m
//  UIA段项目 墨家天气
//
//  Created by dllo on 15/8/25.
//  Copyright (c) 2015年 dllo. All rights reserved.
//

#import "SmallLiveCollectiontViewCell.h"
#import "LiveCollectionCell.h"
@implementation SmallLiveCollectiontViewCell
-(void)dealloc
{
    [_lable release];
    [_imageV release];
    [super dealloc];
}
- (instancetype)initWithFrame:(CGRect)frame
{
    
    self = [super initWithFrame:frame];
    
    
    if (self) {
        
        [self a];
    }
    return self;
}

- (void)a
{
    self.imageV = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, 125 * OffWidth, 120 * OffHeight)];
    [self.contentView addSubview:_imageV];
    [_imageV release];
    
    self.lable = [[UILabel alloc]initWithFrame:CGRectMake(0, 90 * OffHeight, 110 * OffWidth, 30 * OffHeight)];
    self.lable.textColor = [UIColor whiteColor];
    self.lable.font = [UIFont boldSystemFontOfSize:13];
    [self.contentView addSubview:_lable];

    [_lable release];
}
- (void)sendTEMP:(NSInteger)temp
{
    self.temp = temp;
    if (temp) {
        
    
    
    self.imageV.frame = CGRectMake(5 * OffWidth, 0, self.contentView.frame.size.width - 10 * OffHeight, self.contentView.frame.size.height - 5 * OffHeight);
    self.lable.frame =  CGRectMake(5 * OffWidth, 115 * OffHeight, self.contentView.frame.size.width - 10 * OffWidth, 30 * OffHeight);
        self.lable.backgroundColor = [UIColor blackColor];
    self.lable.textColor = [UIColor whiteColor];
        self.lable.alpha = 0.5;
    self.lable.font = [UIFont boldSystemFontOfSize:15];

    }else{
        self.imageV.frame = CGRectMake(2 * OffWidth, 2, self.contentView.frame.size.width - 5* OffHeight, self.contentView.frame.size.height - 5 * OffHeight);
        self.lable.frame =  CGRectMake(0 * OffWidth, 100 * OffHeight, self.contentView.frame.size.width + 5 * OffWidth, 18 * OffHeight);
        self.lable.textColor = [[UIColor whiteColor]colorWithAlphaComponent:1];
        self.lable.font = [UIFont boldSystemFontOfSize:13];

        
        
        
    }
}


@end
